/**   
 * @Title: SysRoleDaoImpl.java 
 * @Package com.leesche.zcsp.node.dao.impl 
 * @Description:() 
 * @author dennies yang
 * @date 2016年9月22日 下午3:29:58 
 * @version V1.0   
 */
package com.leesche.zcsp.node.web.dao.impl;

import java.util.List;

import com.leesche.zcsp.node.web.dao.SysRoleDao;
import com.leesche.zcsp.node.web.model.SysRole;
import com.leesche.zcsp.node.web.model.SysRoleCriteria;
import com.leesche.zcsp.node.web.model.SysUser;
import com.leesche.zcsp.node.web.service.impl.data.read.QuerySysRoleCondition;
import com.leesche.zcsp.node.web.service.impl.data.read.SysRoleDto;
import com.leesche.zcsp.node.web.service.impl.data.read.SysUserDto;

/**
 * @Title: SysRoleDaoImpl.java
 * @Package com.leesche.zcsp.node.dao.impl
 * @Description:()
 * @author dennies yang
 * @date 2016年9月22日 下午3:29:58
 * @version V1.0
 */
public class SysRoleDaoImpl
		extends
		BaseDaoImpl<SysRole, SysRoleCriteria, SysRoleDto, QuerySysRoleCondition, Long>
		implements SysRoleDao {

	@Override
	public List<SysRole> selectByParentTree() {
		// TODO Auto-generated method stub return null;
		return this.getSqlSession().selectList(
				this.getStatement("selectByParentTree"));
	}

	@Override
	public List<SysRole> selectByRoleNtypes(List<SysUser> sysUser) {
		// TODO Auto-generated method stub return null;
		return this.getSqlSession().selectList(
				this.getStatement("selectByRoleNtypes"),sysUser);
	}

	@Override
	public List<SysRole> selectByDifferentUser(SysUserDto sysUserDto) {
		// TODO Auto-generated method stub return null;
		return this.getSqlSession().selectList(
				this.getStatement("selectByDifferentUser"),sysUserDto);
	}

	@Override
	public int selectRoleTotal() {
		// TODO Auto-generated method stub return 0;
		return this.getSqlSession().selectOne(this.getStatement("selectRoleTotal"));
	}

	@Override
	public List<SysRole> selectChildRoleByBusinessUser(Long userid) {
		return this.getSqlSession().selectList(
				this.getStatement("selectChildRoleByBusinessUser"),userid);
	}

	@Override
	public int insertBatch(List<SysRole> roles) {
		return 0;
	}

	@Override
	public List<SysRole> selectChildRoleByCondition(QuerySysRoleCondition condition) {
		return null;
	}
}
